home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / dirut / nfd104.zip / NFD.DOC < prev   
Text File  |  1987-11-25  |  7KB  |  184 lines

  1.                           NFD utility
  2.                    Version: 1.00  -  07 Mar 86
  3.  
  4.  
  5.  
  6. ********** revision 1.04  25 Nov 87:  revised GetPath for explicit filename use
  7. ********** revision 1.03  28 Oct 87:  revised "Usage . . ." to add switches
  8. ********** revision 1.02  20 Oct 87:  revised GetArgs to allow "Usage . . ."
  9.                                       revised for MASM 4.0 assembly
  10. ********** revision 1.01  ?????????
  11.  
  12.     The NFD utility allows setting the date and time stamps for a 
  13. disk  file.  NFD  was developed out of a sort of a combination of 
  14. two other programs;  FDATE and TOUCH.  Since the result  looks  a 
  15. little  more like FDATE,  the name NFD,  signifying New FDATE was 
  16. selected  (in  fact,   this  document  is  little  more  than   a 
  17. modification   of   the   original  FDATE  document.)  The  major 
  18. differences between NFD and FDATE are: 
  19.  
  20.     1.  NFD  can  use  ambiguous  file  name;  i.e.   file  names 
  21.         containing DOS 'wild cards'.  
  22.  
  23.     2.  NFD, by default, gives a console display of its actions.  
  24.  
  25.     3.  NFD, by default, will query the operator for confirmation 
  26.         before changing the Date/Time of any file.  
  27.  
  28.  
  29. USAGE:
  30.  
  31. The syntax of the command is:
  32.  
  33.     NFD  [filename] [date] [time] [switches]
  34.  
  35.     Where  the filename must be specified and may be any standard 
  36. DOS path name and the File Name element  may  contain  DOS  'wild 
  37. cards'.  
  38.      
  39.     The date,  time,  and switches are optional and can appear in 
  40. any order.  
  41.  
  42.     Date can be mm/dd/yy or mm-dd-yy.
  43.  
  44.     Time is  hh:mm:ss with the seconds optional
  45.  
  46.     The switches are either  '\n'  or  '\s'  or  both.  The  '\n' 
  47. switch  indicate  No  Query;  the  normal mode of operation is to 
  48. query the operator prior to changing the Date/Time for each file.  
  49. If the '\n' switch is used,  the  change  will  be  made  without 
  50. querying   the   operator.   The  '\s'  switch  indicates  Silent 
  51. operations.  By default,  for each file changed,  the file  name, 
  52. the  old Date/Time,  and the new Date/Time will be displayed.  If 
  53. the '\s' switch is used, this display will be suppressed.  
  54.  
  55.     If  either  the  date  or  time  or  both are specified,  the 
  56. respective date and time information in the directory  entry  for 
  57. the  file  is  set appropriately.  If only one is specified,  the 
  58. other is left with its original value.  If neither  the  date  or 
  59. time  is specified on the command line,  then the file's date and 
  60. time stamps are set from the current date and  time  in  the  DOS 
  61. clock.  
  62.  
  63.     The   filename   can   include   normal   drive   and    path 
  64. specifications.  
  65.  
  66. Warning: Although most cases of illegal  date  and  time  formats 
  67.          will be detected,  it was not deemed worth the effort or 
  68.          memory to  try  and  detect  all  possible  pathological 
  69.          cases,  so  trying  to  fool  it  will not lead to happy 
  70.          directory entries.  
  71.  
  72. Note:  The time recorded by DOS in the directory entry is kept in 
  73.        TWO second intervals, so the second specified is truncated 
  74.        to an even value.  
  75.  
  76.  
  77. EXAMPLES:
  78.  
  79.     1.  The following command would change the Date/Time of every 
  80.         file in the DOS 'current' directory the the current  date 
  81.         and time: 
  82.  
  83.         A>NFD *.*
  84.  
  85.         For each file,  NFD would display the file name,  the old 
  86.         time  and  date,  and  the  new time and date and request 
  87.         confirmation of  the  change  from  the  operator  before 
  88.         making  the  change  as shown below (the display has been 
  89.         shortened slightly to fit the page format:) 
  90.  
  91.         NFD Version: 1.00  -  7 Mar 86
  92.  
  93.         NFD.000
  94.             From: 03-07-86 17:38    To: 03-07-86 17:51  Change? y
  95.         NFD.ASM
  96.             From: 03-07-86 17:38    To: 03-07-86 17:51  Change? y
  97.         NFD.COM
  98.             From: 03-07-86 17:38    To: 03-07-86 17:51  Change? y
  99.         NFD.DOC
  100.             From: 03-07-86 17:50    To: 03-07-86 17:51  Change? y
  101.  
  102.  
  103.     2.  The following command would change the Date/Time of every 
  104.         file in the DOS 'current' directory to 02/23/84 at 11:45: 
  105.  
  106.         A>NFD *.* 02/23/84 11:45
  107.  
  108.         again,  before making the change for each file,  NFD will 
  109.         request confirmation from the operator as shown below:
  110.  
  111.         NFD Version: 1.00  -  7 Mar 86
  112.  
  113.         NFD.000
  114.             From: 03-07-86 17:51    To: 02-23-84 11:45  Change? y
  115.         NFD.ASM
  116.             From: 03-07-86 17:51    To: 02-23-84 11:45  Change? y
  117.         NFD.COM
  118.             From: 03-07-86 17:51    To: 02-23-84 11:45  Change? y
  119.         NFD.DOC
  120.             From: 03-07-86 17:56    To: 02-23-84 11:45  Change? y
  121.  
  122.  
  123.     3.  The following command would change the Date/Time of every 
  124.         file  in  the 'current' directory to the current time and 
  125.         date without requesting operator confirmation: 
  126.  
  127.         A>NFD *.* /N
  128.  
  129.         NFD Version: 1.00  -  7 Mar 86
  130.  
  131.         NFD.000
  132.             From: 02-23-84 11:45    To: 03-07-86 18:00
  133.         NFD.ASM
  134.             From: 02-23-84 11:45    To: 03-07-86 18:00
  135.         NFD.COM
  136.             From: 02-23-84 11:45    To: 03-07-86 18:00
  137.         NFD.DOC
  138.             From: 03-07-86 18:00    To: 03-07-86 18:00
  139.  
  140.     
  141.     4.  The following command would change the Date/Time of every 
  142.         file in the current directory to  the  current  time  and 
  143.         date without requesting operator confirmation and without 
  144.         showing the changes being made: 
  145.  
  146.         A>NFD *.* /NS
  147.  
  148.         I believe that an example of the output for this form  of 
  149.         the command is unnecessary.
  150.  
  151.     5.··Finally, NFD can also change just a specific file:
  152.  
  153.         A>NFD NFD.DOC
  154.  
  155.         NFD Version: 1.00  -  7 Mar 86
  156.  
  157.         NFD.COM
  158.             From: 03-07-86 18:00    To: 03-07-86 18:37  Change? y
  159.  
  160.         All of the options for dates,  times,  and switches apply 
  161.         regardless of the form of the file name.  
  162.  
  163.  
  164. COMMENTS:
  165.  
  166.     I am dubious of the general utility of NFD,  I don't  believe 
  167. that  many  people  have  a frequent need to change the Date/Time 
  168. stamping of their files, however, NFD was developed because I did 
  169. have a very real need to change  them  on  my  system  and  other 
  170. people  may  well  encounter  similar circumstances.  Someone,  I 
  171. believe that it  was  Sol  Libes  of  MicroSystems/Journal,  once 
  172. referred  the the Public Domain software collection for CP/M as a 
  173. "spare parts bin for hackers".  I believe that his assessment was 
  174. valid if you use the term "hacker' in its older  sense,  most  of 
  175. the work that I did on CP/M contained portions removed from other 
  176. Public  Domain  programs.  Neither  FDATE  nor  TOUCH carried any 
  177. copyright notices,  either in the documentation or  in  the  code 
  178. itself,  a  rare  circumstance  in the 16-bit world of PC/MS-DOS!  
  179. This program, which contains pieces of both as well as some of my 
  180. own original code, is NOT copyrighted!  
  181.  
  182.     Don A.Williams
  183.  
  184.